package me.nareshkumarrao.IRCraft;


import org.bukkit.Bukkit;
import org.bukkit.Server;
import org.jibble.pircbot.PircBot;

public class IRCraftBot extends PircBot {
	public static IRCraft plugin;
	
	public IRCraftBot(String nick)
	{
		this.setName(nick);
	}
	public void onMessage(String channel, String sender, String login, String hostname, String message)
	{
		Server send = Bukkit.getServer();
		send.broadcastMessage("[IRC]<"+sender+"> "+message);
	}
	public void getInstance(IRCraft instance)
	{
		plugin = instance;
	}
	public void onChannelInfo(String channel, int userCount, String topic)
	{
		plugin.CommSender.sendMessage(channel+"["+userCount+"]");
	}
	
}
